import math

file = r'"\\DESKTOP-FNB9JOL\Repository\Country\Hong Kong\功夫 (2004)\功夫.mp4"'
dest = r'"\\DESKTOP-FNB9JOL\Repository\Country\Hong Kong\功夫 (2004)\你條蛤𧊅，羊牯扮叔父.mp4"'
start = 23752
end = 24439
fps = 23.976

ms = (start % fps) / 24
s = (start//fps) % 60
m = (start//fps//60) % 60
h = start//fps//60//60

start_time = str(math.floor(h)).zfill(2) + ':' + str(math.floor(m)).zfill(2) + ':' + str(round(s + ms, 3))

f = end - start

ms = (f % fps) / 24
s = (f//fps) % 60
m = (f//fps//60) % 60
h = f//fps//60//60

duration_time = str(math.floor(h)).zfill(2) + ':' + str(math.floor(m)).zfill(2) + ':' + str(round(s + ms, 3))

print("ffmpeg -ss %s -t %s -i %s -vcodec copy %s" % (start_time, duration_time, file, dest))
